package com.itfreer.gis.locus.data;

import com.alibaba.dubbo.config.annotation.Reference;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.itfreer.form.api.BaseRestService;
import com.itfreer.form.api.BaseService;
import com.itfreer.gis.locus.data.entity.LocusEventEntity;

import io.swagger.annotations.Api;

/**
 * 巡护事件
 */
@RestController
@RequestMapping("/locusevent")
@Api("巡护事件")
public class RestLocusEventService extends BaseRestService<LocusEventEntity> {

	@Autowired(required = false)
	private LocusEventService service;

	@Reference(
			lazy = true,
			check = false
	)
	private LocusEventService dubboService;

	@Override
	protected BaseService<LocusEventEntity> getService() {
		return this.service == null ? this.dubboService : this.service;
	}
}
